QUERY_ALL_SKU_BATCH = " \
             SELECT \
             skuBatch.id, \
             skuBatch.goods_id as goodsId, \
             IFNULL(goods.goods_name,'') as goodsName, \
             CASE \
             WHEN goods.create_at < 1584288000 THEN goods.old_goods_id \
             ELSE skuBatch.sku_id \
             END as skuId, \
             skuBatch.batch_sn as batchSn, \
             skuBatch.warehouse_id AS warehouseId, \
             CASE skuBatch.warehouse_id \
             WHEN 1 THEN '南京仓库' \
             WHEN 2 THEN '深圳仓库' \
             END AS warehouseName, \
             sum(skuBatch.inventory) as inventory, \
             0 as warehouseInventory \
             FROM \
             goods_sku_batch_inventory skuBatch \
             LEFT JOIN goods goods on goods.id = skuBatch.goods_id \
             WHERE skuBatch.if_del =1 \
             AND skuBatch.inventory != 0 \
             AND skuBatch.warehouse_id = '%s' \
             group by skuBatch.sku_id "
